package com.yunhe.java.day05;

import java.util.Arrays;

/**
 * Created by Administrator on 2017/7/26 0026.
 */
public class ArrFour {
    public static void main(String[] args) {
        int [] arr={1,2,5,3,4,6,5,2,8};
        int [] arr1= Arrays.copyOfRange(arr,3,6);
        Arrays.sort(arr);
        Arrays.fill(arr,0);
        Arrays.fill(arr,2,7,1);
        boolean b = Arrays.equals(arr,arr1);
        int [] arr2=Arrays.copyOf(arr,6);
        System.out.println(Arrays.toString(arr1));
        System.out.println(Arrays.toString(arr));
        System.out.println(Arrays.toString(arr2));
        System.out.println(b);
    }
}
